﻿@model IEnumerable<TruckingApplication.Dal.EntityModels.RESOURCE>

@{
    ViewBag.Title = "Index";
}

<h2>Index</h2>

<p>
    @Html.ActionLink("Create New", "Create")
</p>
<table>
    <tr>
        <th>
            firstName
        </th>
        <th>
            lastName
        </th>
        <th>
            address
        </th>
        <th>
            city
        </th>
        <th>
            state
        </th>
        <th>
            zip
        </th>
        <th>
            startDate
        </th>
        <th>
            ssNum
        </th>
        <th>
            taxID
        </th>
        <th>
            email
        </th>
        <th>
            phone
        </th>
        <th>
            commission
        </th>
        <th>
            RESOURCE_TYPE
        </th>
        <th>
            mcNumber
        </th>
        <th>
            factoringFee
        </th>
        <th></th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.firstName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.lastName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.address)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.city)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.state)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.zip)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.startDate)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.ssNum)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.taxID)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.email)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.phone)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.commission)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.RESOURCE_TYPE.resourceType)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.mcNumber)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.factoringFee)
        </td>
        <td>
            @Html.ActionLink("Edit", "Edit", new { id=item.resourceID }) |
            @Html.ActionLink("Details", "Details", new { id=item.resourceID }) |
            @Html.ActionLink("Delete", "Delete", new { id=item.resourceID })
        </td>
    </tr>
}

</table>
